package com.laowang.project.system.domain;

import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.laowang.framework.aspectj.lang.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;

/**
 * 优惠券对象 tb_coupons
 *
 * @author laowang
 * @date 2022-08-24
 */
@NoArgsConstructor
@Data
public class TbCoupons implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * $column.columnComment
     */
    @ApiModelProperty(value = "${comment}", required = false)
    private Long id;

    /**
     * 分享者id
     */
    @Excel(name = "分享者手机号")
    @NotBlank(message = "分享者手机号不能为空")
    @ApiModelProperty(value = "分享者手机号", required = false)
    private String shareUserPhone;

    /**
     * 被分享者id
     */
    @Excel(name = "被分享者手机号")
    @NotBlank(message = "被分享者手机号不能为空")
    @ApiModelProperty(value = "被分享者手机号", required = false)
    private String toUserPhone;

    /**
     * 优惠券标题
     */
    @Excel(name = "优惠券标题")
    @ApiModelProperty(value = "优惠券标题", required = false)
    private String title;

    /**
     * 优惠券描述
     */
    @Excel(name = "优惠券描述")
    @ApiModelProperty(value = "优惠券描述", required = false)
    private String describe;

    /**
     * 生效时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "生效时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "生效时间", required = false)
    private Date startTime;

    /**
     * 到期时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "到期时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "到期时间", required = false)
    private Date endTime;

    /**
     * 是否核销
     */
    @Excel(name = "是否核销")
    @ApiModelProperty(value = "是否核销", required = false)
    private Integer isCheck;


}
